<style>
.fui-header a.back:before {
	content: " ";
	border-color: #fff;
}
.fui-cell-group .fui-cell:before {
	border-bottom: 0 solid #ebebeb;
}
</style>
<div class="fui-page order-create-page fui-page-current" ng-if="pagedata.op == 'detail'">
	<div class="fui-header" style="z-index:108;background-color:#18bc9c;position: fixed;">
				<div class="fui-header-left">
					<span style="color:#fff">满意度问卷调查</span>
				</div>
				<div class="title bold" style="font-size:1rem;color:#fff"></div>
				<div class="fui-header-right" style="padding-right:0.5rem;color:#fff;">
						<div class="icon icon-ship r-f" style="font-size:1rem;padding-left:0.5rem" href="javascript:;" ng-click="pagedata.showcard=true;"></div>
				</div>
		</div>
		<div class="fui-cell-group" style="width:100%;position: fixed;top:2rem;margin-top:0;z-index:108">
				<div class="fui-cell">
						<div class="fui-cell-icon"><i class="icon icon-quanbudingdan"></i></div>
						<div class="fui-cell-text">{{pagedata.item.title}}</div>
						<div class="fui-cell-remark noremark" style="color:#999">一共{{pagedata.allnum}}道题</div>
				</div>
		</div>
	<div class="fui-content" style="margin-top:5rem">
		<div ng-if="false" class="weui_cells_title c bold">问卷介绍</div>
		<div ng-if="pagedata.item.desc && false" class="weui_cells_title c">{{pagedata.item.desc}}</div>
		<div ng-if="false" class="fixed-title" style="margin-top:0.5rem">
							 <span class="befirst spacing">
								 <span class="icon icon-fengexianzuo" style="font-size:2rem;color:#666"></span>
							 </span> 
							 <span class="title-text bold" style="color:#333;line-height:2rem">开始答题</span> 
							 <span class="spacing">
								 <span class="icon icon-fengexianyou" style="font-size:2rem;color:#666"></span>
							 </span>
		</div>
		<div style="padding:0 0.6rem" ng-include="sys_html('_ti_item')"></div>
		<div class="content-empty" ng-show="!pagedata.post.content || pagedata.post.content.length == 0 ">
		  <i class="icon jinyunicon icon-cry" style="width: 6rem;margin-bottom: 0.5rem;font-size:2rem"></i><br/><p style="color: #999;font-size: .75rem">没有任何题目！</p>
		</div>
		<div ng-show="pagedata.post.content.length >0 && false" class="weui_btn_area">
			 <a class="weui_btn weui_btn_primary" href="javascript:"  ng-click="pagedata.checkpost=true">提交问卷</a>
		</div>
	</div>
</div>
<div ng-if="pagedata.checkpost" class="popup">
	<div class="popup-body">
		<div class="popup-center">
			<i class="closed icon icon-cuowu" ng-click="pagedata.checkpost=false"></i>
			<div class="weui_msg">
					<div class="weui_text_area">
						<p class="weui_msg_title">确认提交问卷？</p>
					</div>
					<div class="weui_text_area" style="padding-bottom:1rem">
						<p class="weui_msg_desc">提交问卷后，将不能再二次修改答案了！</p>
					</div>
					<div class='fui-cell-group' style="padding-bottom:1rem">
						<div class="fui-cell">
							<label class="fui-cell-label" style="width: 5rem;">{{pagedata.item.type==1?'选择售后':'选择售后主管'}}</label>
							<div class="fui-cell-info">
								<select ng-model="pagedata.post.workerid" style="background-color:#f2f2f2;padding:0.2rem;height:auto">
										<option ng-repeat="item in pagedata.workers" value="{{item.id}}" ng-selected="pagedata.post.workerid==item.id">{{item.title}}</option>
								</select>
							</div>
						</div>
						<div class="fui-cell">
							<div class="fui-cell-label" style="width: 5rem;">售后姓名</div>
							<div class="fui-cell-info">
							<input type="text" name="name" class='fui-input' style="background-color:#f2f2f2" ng-model="pagedata.post.name" value="{{pagedata.post.name}}"/>
							</div>
						</div>
						<div class="fui-cell">
							<div class="fui-cell-label" style="width: 5rem;">售后编号</div>
							<div class="fui-cell-info">
							<input type="text" name="name" class='fui-input' style="background-color:#f2f2f2" ng-model="pagedata.post.sn" value="{{pagedata.post.sn}}" max="25"/>
							</div>
						</div>
					</div>
					<div class="modal-footer">
						<div class="mod-fail" ng-click="pagedata.checkpost=false;">我再看看</div>
						<div class="mod-success" ng-click="pagedata.diyfrompost()">确认提交</div>
					</div>
			</div>
		</div>
		
	</div>
</div>
<div ng-if="pagedata.needdesc" class="popup">
	<div class="popup-body">
		<div class="popup-center">
			<div class="weui_msg">
					<div class="weui_text_area">
						<p class="weui_msg_title">{{pagedata.item.title}}</p>
					</div>
					<div class='fui-cell-group' style="padding:0 0.5rem;padding-bottom:1rem">
						<p class="gray">{{pagedata.item.desc}}</p>
					</div>
					<div class="modal-footer">
						<div class="mod-check" ng-click="pagedata.needdesc=false;">开始评分</div>
					</div>
			</div>
		</div>
		
	</div>
</div>
<div class="fui-navbar">
    <a href="javascript:;" ng-click="pagedata.onitem();" class="nav-item">
        <span class="label">上一题</span>
    </a>
	<a class="external nav-item">
        <span class="label"><span class="syscolor">{{pagedata.nowkey+1}}</span>/{{pagedata.allnum}}</span>
    </a>
	<a ng-if="pagedata.nowkey+1!=pagedata.allnum" href="javascript:;" ng-click="pagedata.nextitem();" class="nav-item">
        <span class="label">下一题</span>
    </a>
	<a ng-if="pagedata.nowkey+1==pagedata.allnum" href="javascript:;" ng-click="pagedata.checkpost=true;" class="nav-item">
        <span class="label">提交问卷</span>
    </a>
</div>
<script type="text/javascript">
scope.pagedata.toitem=function(nowkey){
	scope.pagedata.nowitem=scope.pagedata.post.content[nowkey];
	scope.pagedata.showcard=false
	scope.$evalAsync();
}
scope.pagedata.diyfrompost=function(){
	if(!scope.pagedata.post.name || !scope.pagedata.post.sn){
		scope.message('请先提交！售后姓名,售后编号','error');
		return false;
	}
	scope.post_json('/diaocha/post/',scope.pagedata.post,function(){
		
	});
}
</script>
